package com.qdlc.p2p.biz.processor.task;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.qdlc.p2p.biz.processor.event.BondTenderValueEvent;
import com.qdlc.p2p.biz.service.BondTenderService;
import com.qdlc.p2p.common.core.queue.TaskProcessorException;
import com.qdlc.p2p.common.core.queue.ValueEvent;

@Service
public class BondTenderTaskProcessor extends AbstractTaskProcessor{

	@Autowired
	BondTenderService bondTenderService;
	
	@Override
	protected void process0(ValueEvent event) throws TaskProcessorException {
//		BondTenderValueEvent valueEvent = (BondTenderValueEvent)event;
//		bondTenderService.addBondTender(valueEvent.getBondModel());
		System.out.println("++++ task BondTenderTaskProcessor.");
	}

	@Override
	public boolean supports(ValueEvent event) {
		// TODO Auto-generated method stub
		return event instanceof BondTenderValueEvent;
	}

}
